package com.rzx.mybackend.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.github.pagehelper.Page;
import com.rzx.mybackend.dto.BuyMerchandiseDTO;
import com.rzx.mybackend.dto.MerchandisePageDTO;
import com.rzx.mybackend.entity.Merchandise;
import org.apache.ibatis.annotations.Mapper;

/**
 * MerchandiseMapper
 *
 * @author renzhexian
 * @date 2025/8/13
 */
@Mapper
public interface MerchandiseMapper extends BaseMapper<Merchandise>{

    Page<Merchandise> query(MerchandisePageDTO merchandisePageDTO);

    void releaseStock(Long merchandiseId, int totalQuantity);
}
